package com.yan.gulimall.member.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.yan.common.utils.PageUtils;
import com.yan.gulimall.member.entity.MemberEntity;
import com.yan.gulimall.member.exception.PhoneExistException;
import com.yan.gulimall.member.exception.UsernameExistException;
import com.yan.gulimall.member.vo.MemberLoginVo;
import com.yan.gulimall.member.vo.MemberRegisterVo;
import com.yan.gulimall.member.vo.SocialUserVo;

import java.util.Map;

/**
 * 
 *
 * @author yan
 * @email yan@gmail.com
 * @date 2020-12-22 14:13:37
 */
public interface MemberService extends IService<MemberEntity> {

    PageUtils queryPage(Map<String, Object> params);

    void register(MemberRegisterVo vo);

    void checkPhoneUnique(String phone) throws PhoneExistException;

    void checkUsernameUnique(String username) throws UsernameExistException;

    MemberEntity login(MemberLoginVo vo);

    MemberEntity login(SocialUserVo vo) throws Exception;
}

